home *** CD-ROM | disk | FTP | other *** search
- #ifndef __CONTEXTUALMENU__
- #define __CONTEXTUALMENU__
-
- #ifndef __APPLEEVENTS__
- #include <AppleEvents.h>
- #endif
- #ifndef __EVENTS__
- #include <Events.h>
- #endif
- #ifndef __MENUS__
- #include <Menus.h>
- #endif
-
-
-
- #if PRAGMA_ONCE
- #pragma once
- #endif
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- #if PRAGMA_IMPORT
- #pragma import on
- #endif
-
- #if PRAGMA_STRUCT_ALIGN
- #pragma options align=mac68k
- #elif PRAGMA_STRUCT_PACKPUSH
- #pragma pack(push, 2)
- #elif PRAGMA_STRUCT_PACK
- #pragma pack(2)
- #endif
-
- /* Gestalt Selector for classic 68K apps only. */
- /* CFM apps should weak link and check the symbols. */
-
- enum {
- gestaltContextualMenuAttr = FOUR_CHAR_CODE('cmnu'),
- gestaltContextualMenuUnusedBit = 0,
- gestaltContextualMenuTrapAvailable = 1
- };
-
- /* Values indicating what kind of help the application supports */
-
- enum {
- kCMHelpItemNoHelp = 0,
- kCMHelpItemAppleGuide = 1,
- kCMHelpItemOtherHelp = 2
- };
-
- /* Values indicating what was chosen from the menu */
-
- enum {
- kCMNothingSelected = 0,
- kCMMenuItemSelected = 1,
- kCMShowHelpSelected = 3
- };
-
- EXTERN_API( OSStatus )
- InitContextualMenus (void) TWOWORDINLINE(0x7001, 0xAA72);
-
- EXTERN_API( Boolean )
- IsShowContextualMenuClick (const EventRecord * inEvent) TWOWORDINLINE(0x7002, 0xAA72);
-
- EXTERN_API( OSStatus )
- ContextualMenuSelect (MenuHandle inMenu,
- Point inGlobalLocation,
- Boolean inReserved,
- UInt32 inHelpType,
- ConstStr255Param inHelpItemString,
- const AEDesc * inSelection,
- UInt32 * outUserSelectionType,
- SInt16 * outMenuID,
- UInt16 * outMenuItem) TWOWORDINLINE(0x7003, 0xAA72);
-
- EXTERN_API( Boolean )
- ProcessIsContextualMenuClient (ProcessSerialNumber * inPSN) TWOWORDINLINE(0x7004, 0xAA72);
-
-
-
- #if PRAGMA_STRUCT_ALIGN
- #pragma options align=reset
- #elif PRAGMA_STRUCT_PACKPUSH
- #pragma pack(pop)
- #elif PRAGMA_STRUCT_PACK
- #pragma pack()
- #endif
-
- #ifdef PRAGMA_IMPORT_OFF
- #pragma import off
- #elif PRAGMA_IMPORT
- #pragma import reset
- #endif
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif /* __CONTEXTUALMENU__ */
-
-